package com.woniu.sso_jwt.jwtresponsedata;

import java.io.Serializable;
/**
 * 发送给客户端的数据对象,其中保存有用户信息，保存在客户端，用于单点登录时
 * 随请求一起发送到服务端进行验证
 *
 * */
public class JWTResponseData implements Serializable {

    private  Integer code; //返回码，类似HTTP的响应码，如200代表成功，500服务器错误
    private Object data;//业务数据
    private String msg;//返回描述
    private String token;//身份标识，JWT生成的令牌

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public Object getData() {
        return data;
    }

    public void setData(Object data) {
        this.data = data;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }

    public JWTResponseData() {
    }

    public JWTResponseData(Integer code, Object data, String msg, String token) {
        this.code = code;
        this.data = data;
        this.msg = msg;
        this.token = token;
    }
}
